﻿using System;
namespace Zinnia.Caching
{
    /// <summary>
    /// 缓存持有者
    /// </summary>
    public interface ICacheHolder : ISingletonDependency
    {
        /// <summary>
        /// 获取缓存对象
        /// </summary>
        /// <typeparam name="TKey"></typeparam>
        /// <typeparam name="TResult"></typeparam>
        /// <param name="component"></param>
        /// <returns></returns>
        ICache<TKey, TResult> GetCache<TKey, TResult>(Type component);
    }
}
